<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<title>Example projects</title>
<title>CMSIS-FreeRTOS: Example projects</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="cmsis.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<script type="text/javascript" src="printComponentTabs.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 46px;">
  <td id="projectlogo"><img alt="Logo" src="CMSIS_Logo_Final.png"/></td>
  <td style="padding-left: 0.5em;">
   <div id="projectname">CMSIS-FreeRTOS
   &#160;<span id="projectnumber">Version 9.0.0</span>
   </div>
   <div id="projectbrief">CMSIS-RTOS2 compliant FreeRTOS Implementation</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<div id="CMSISnav" class="tabs1">
    <ul class="tablist">
      <script type="text/javascript">
		<!--
		writeComponentTabs.call(this);
		//-->
      </script>
	  </ul>
</div>
<!-- Generated by Doxygen 1.8.6 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li class="current"><a href="pages.html"><span>Usage&#160;and&#160;Description</span></a></li>
      <li><a href="modules.html"><span>Reference</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('examples.html','');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Groups</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Pages</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="headertitle">
<div class="title">Example projects </div>  </div>
</div><!--header-->
<div class="contents">
<div class="textblock"><p>This pack contains two example projects:</p>
<ul>
<li><a class="el" href="examples.html#examples_native">Blinky example using FreeRTOS natively</a></li>
<li><a class="el" href="examples.html#examples_cmsis">Blinky example using CMSIS-FreeRTOS</a></li>
</ul>
<p>The first example shows how to use FreeRTOS standalone, whereas the second example shows how to use the CMSIS-RTOS2 API with an underlying FreeRTOS.</p>
<p>The examples simulate a step-motor driver. Four phase variables are simulating the activation of the four output driver stages. The state changes are shown in the Watch window variable <code>g_phases</code>. All four phases are displayed in the Logic Analyzer:</p>
<div class="image">
<img src="blinky_example_simu.png" alt="blinky_example_simu.png"/>
</div>
<h1><a class="anchor" id="examples_native"></a>
Blinky example using FreeRTOS natively</h1>
<p>This example shows how to use FreeRTOS natively in a ÂµVision project. This makes your code portable and you can choose to use a different RTOS kernel anytime during development (even only for evaluation purposes).</p>
<p>To open the example, go to Pack Installer, select <b>ARM</b> in the <b>Devices</b> tab, and click on <b>Copy</b> next to the <b>Native FreeRTOS Blinky (uVision Simulator)</b> project on the <b>Examples</b> tab. Select the location on your hard drive where you want to copy the project to and press OK. ÂµVision opens.</p>
<h1><a class="anchor" id="examples_cmsis"></a>
Blinky example using CMSIS-FreeRTOS</h1>
<p>This example shows how to use the CMSIS-RTOS2 API with an underlying FreeRTOS. This makes your code portable and you can choose to use a different RTOS kernel anytime during development (even only for evaluation purposes).</p>
<p>To open the example, go to Pack Installer, select <b>ARM</b> in the <b>Devices</b> tab, and click on <b>Copy</b> next to the <b>CMSIS-RTOS2 FreeRTOS Blinky (uVision Simulator)</b> project on the <b>Examples</b> tab. Select the location on your hard drive where you want to copy the project to and press OK. ÂµVision opens.</p>
<h1><a class="anchor" id="examples_cmsis_a9"></a>
Blinky example using CMSIS-FreeRTOS running on ARM Cortex-A9</h1>
<p>This example shows how to use the CMSIS-RTOS2 API with an underlying FreeRTOS running on an NXP i.MX6 equipped with an ARM Cortex-A9 code. This example only works in <a href="http://www.keil.com/mdk5/ds-mdk">DS-MDK</a>, the Eclipse-based development environment from ARM. For information on setting up the target connection, please refer to <a href="http://www2.keil.com/mdk5/ds-mdk/imx6sxsabrereference">NXP i.MX 6SoloX SABRE Reference</a>.</p>
<dl class="section note"><dt>Note</dt><dd>you need to have the i.MX6 device family pack installed to see the example in the <b>Examples</b> tab of Pack Installer.</dd></dl>
<p>To open the example, open the Pack Installer perspective, select <b>NXP</b> in the <b>Devices</b> tab, and click on <b>Copy</b> next to the <b>CMSIS-RTOS2 FreeRTOS Blinky CA9 (MCIMX6SX-SABRE)</b> project on the <b>Examples</b> tab.</p>
<div class="image">
<img src="copy_a9_example.png" alt="copy_a9_example.png"/>
</div>
<p>Confirm the default location in the Eclipse Workspace by pressing Copy.</p>
<div class="image">
<img src="copy_a9_example_ws.png" alt="copy_a9_example_ws.png"/>
</div>
<p>Right-click on the project and select <b>Build</b> <b>Project</b>. Then, right-click on the project and select <b>Debug</b> <b>As</b> and then <b>Debug</b> <b>Configurations</b>. The Debug Configurations dialog opens:</p>
<div class="image">
<img src="dbg_conf.png" alt="dbg_conf.png"/>
</div>
<p>The project is already set up for running from the SDRAM of the i.MX6 SABRE board. Press <b>Debug</b>. DS-MDK will switch to the debug perspective. After a successful connection to the target, press <b>F8</b> to run the application. In the <b>App</b> <b>Console</b> you will see the output of the phases:</p>
<div class="image">
<img src="dbg_output.png" alt="dbg_output.png"/>
</div>
 </div></div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="footer">Generated on Mon Mar 13 2017 09:48:26 for CMSIS-FreeRTOS by ARM Ltd. All rights reserved.
	<!--
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.6 
	-->
	</li>
  </ul>
</div>
</body>
</html>
